package com.example.express.service;

import java.util.concurrent.TimeUnit;

/**
 * redis业务
 * @author 周欣
 */
public interface RedisService {

    /**
     * 检测请求流量限制
     * @param key
     * @param expireTime
     * @param max
     * @param timeUnit
     * @param userAgent
     * @return
     */
    boolean checkRequestRateLimit(final String key, final int expireTime, final int max, TimeUnit timeUnit, String userAgent);
}
